<?php

   class Application_Plugin_ModuleMenuLoader extends Zend_Controller_Plugin_Abstract
   {
      public function dispatchLoopStartup(Zend_Controller_Request_Abstract $request)
       {
           $module = $request->getModuleName();

           if($module != 'default')
           {
              $menus=new Application_Model_MenuMapper();
              $rightmenu= $menus-> getMenu('right_menu',$module);
           }
           else
           {
              $rightmenu='';
           }

           Zend_Registry::set('right_menu', $rightmenu);
       }
   }

?>
